//
//  YWSampleType.m
//  百布业务
//
//  Created by 陈炳桦 on 15/11/2.
//  Copyright © 2015年 陈炳桦. All rights reserved.
//  （1：面料 2：辅料）

#import "YWSampleType.h"

@interface YWSampleType() <NSCoding>

@end

@implementation YWSampleType

+ (NSDictionary *)replacedKeyFromPropertyName
{
    return @{
             @"ID" : @"id",
             };
}

#pragma mark - 自定义归档
- (void)encodeWithCoder:(NSCoder *)aCoder{
    
    [aCoder encodeObject:self.name forKey:@"name"];
    [aCoder encodeObject:self.ID forKey:@"ID"];


}

- (nullable instancetype)initWithCoder:(NSCoder *)aDecoder{
    if (self = [super init]) {
        self.name=[aDecoder decodeObjectForKey:@"name"];
        self.ID = [aDecoder decodeObjectForKey:@"ID"];
    }
    return self;
}

@end
